﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="SetUser.aspx.cs" Inherits="iEN.PlatformSet.SetUser" %>

<%@ Register src="../UserControl/TopMenu.ascx" tagname="TopMenu" tagprefix="uc2" %>

<%@ Register assembly="DundasWebGauge" namespace="Dundas.Gauges.WebControl" tagprefix="DGWC" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
    <title>帳號管理</title>
    <script type="text/javascript">
        function EndRequestHandler(sender, args) {
            if (args.get_error() != undefined) {
                var code = args.get_response().get_statusCode(); // 0, 500, 503, 12007, 12029, 12031
                //alert('EndRequestHandler: ' + code);
                //clear error
                args.set_errorHandled(true);
                // alert('網路暫時無法連線，請重試！');   
            }
        }
        function init() {
            Sys.WebForms.PageRequestManager.getInstance().add_endRequest(EndRequestHandler);
            Sys.Application.add_load(
            function () {
                var form = Sys.WebForms.PageRequestManager.getInstance()._form;
                form._initialAction = form.action = window.location.href;
            }
            );
        }
    </script>
    <style type="text/css">
        #IMap
        {
            width: 952px
         }
        .style1
        {
            height: 36px;
        }
        .style3
        {
            height: 159px;
        }
    </style>
</head>
<body onload="init();">
    <form id="form1" runat="server">
    <uc2:TopMenu ID="TopMenu1" runat="server" />
        <center>
    <asp:ScriptManager ID="ScriptManager1" runat="server" />     
        <asp:Label ID="lblMsg" runat="server" Font-Names="微軟正黑體" Font-Size="X-Large" 
                        ForeColor="Red" Text="你沒有瀏覽此頁面的權限" Visible="False"></asp:Label>
        <asp:Panel ID="Panel1" runat="server">
        <table>
            <tr>
                <td style="background-image:url('../images/title_back.gif')" align="center" ; 
                    width="952px" class="style1" >
                    <asp:Label ID="Label1" runat="server" Text="帳號管理" BackColor="Transparent" 
                        style="color:Blue;background-color:Transparent;font-family:標楷體;font-size:XX-Large;"></asp:Label>
                </td>
            </tr>
            <tr><td class="style3"><asp:UpdatePanel ID="UpdatePanel1" 
                    runat="server">
                <ContentTemplate>
                    <asp:GridView ID="gvUser" runat="server" AutoGenerateColumns="False" 
                        CellPadding="4" ForeColor="#333333" GridLines="None" Height="178px" 
                        HorizontalAlign="Left" Width="600px" Caption="系統所有使用者清單" 
                        Font-Size="Large" onselectedindexchanged="gvUser_SelectedIndexChanged" 
                        style="margin-right: 0px" onrowcommand="gvUser_RowCommand" PageSize="999">
                        <AlternatingRowStyle BackColor="White" Font-Size="Medium" />
                        <Columns>
                            <asp:BoundField DataField="Account" HeaderText="登入帳號" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Username" HeaderText="客戶名稱" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Mobilephone" HeaderText="行動電話" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Type" HeaderText="類型" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:BoundField DataField="Email" HeaderText="電子郵件" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:BoundField>
                            <asp:HyperLinkField DataNavigateUrlFormatString="~/PlatformSet/UserDetail.aspx?Account={0}" 
                                HeaderText="編輯與刪除" NavigateUrl="~/PlatformSet/UserDetail.aspx" Text="詳細資料" 
                                DataNavigateUrlFields="Account" >
                            <ItemStyle HorizontalAlign="Center" />
                            </asp:HyperLinkField>
                        </Columns>
                        <EditRowStyle BackColor="#2461BF" />
                        <FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
                        <HeaderStyle BackColor="#507CD1" Font-Bold="True" Font-Size="Medium" 
                            ForeColor="White" />
                        <PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
                        <RowStyle BackColor="#EFF3FB" Font-Size="Medium" Width="300px" />
                        <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
                        <SortedAscendingCellStyle BackColor="#F5F7FB" />
                        <SortedAscendingHeaderStyle BackColor="#6D95E1" />
                        <SortedDescendingCellStyle BackColor="#E9EBEF" />
                        <SortedDescendingHeaderStyle BackColor="#4870BE" />
                    </asp:GridView>
                </ContentTemplate>
                </asp:UpdatePanel>
                </td></tr>

                <tr><td align="left">&nbsp;<asp:Button ID="Button1" runat="server" 
                        Font-Size="Medium" Height="30px" onclick="Button1_Click" Text="新增帳號" />
                </td></tr>
        </table>
        </asp:Panel>
        </center>
</form>
</body>
</html>